<template>
  <div class="brand-detail">
      <div class="main">
        <div class="banner">
          <img :src="detailInfo.list_pic_url" alt="" />
          <div class="title">
            {{ detailInfo.name }}
          </div>
        </div>
        <div class="desc">
          {{ detailInfo.simple_desc }}
        </div>
        <ul class="list">
          <li v-for="item in goodsList" :key="item.id">
            <img :src="item.list_pic_url" alt="" />
            <p class="name">{{ item.name }}</p>
            <p class="price">￥{{ item.retail_price }}</p>
          </li>
        </ul>
        <van-empty class="empty_icon" v-if="goodsList.length == 0" description="暂无数据" />
      </div>
    </div>
</template>
<script>
import { detailaction } from "@/api/home/brand";
export default {
  data() {
    return {
      detailInfo: {},
      goodsList: [],
    };
  },
  created() {
    detailaction({
      id: this.$route.query.id,
    }).then((res) => {
      console.log(res);
      this.detailInfo = res.data.data;
      this.goodsList = res.data.goodsList;
    });
  },
};
</script>
<style lang="scss" scoped>
@import "./index.scss";
</style>
